<html>
<head><meta charset="utf-8"><title>cc-rs update improved performance? · t-compiler/performance · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/index.html">t-compiler/performance</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html">cc-rs update improved performance?</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="210816736"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210816736" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210816736">(Sep 22 2020 at 00:25)</a>:</h4>
<p>In <a href="https://github.com/rust-lang/rust/pull/76880#issuecomment-696435457">https://github.com/rust-lang/rust/pull/76880#issuecomment-696435457</a>, <span class="user-mention" data-user-id="118594">@ecstatic-morse</span> said:</p>
<blockquote>
<p>Hi! This PR showed up in the weekly <a href="https://github.com/rust-lang/rustc-perf/tree/master/triage">perf triage</a> report. It resulted in a moderate improvement in <a href="https://perf.rust-lang.org/compare.html?start=8e9d5db8392c44a2e94008168fa3506ecddaa357&amp;end=b3aae050cd7e0c9a9eb6085bd49b02f67dc1396f&amp;stat=instructions:u">instruction counts</a> (up to -1.0% on <code>incr-patched: Compiler new</code> builds of <code>regex-opt</code>).</p>
<p>This seems to have been a very small win across the board, including <code>rustdoc</code>.</p>
</blockquote>
<p><span class="user-mention" data-user-id="116122">@simulacrum</span> does that make any sense to you?</p>



<a name="210816835"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210816835" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210816835">(Sep 22 2020 at 00:27)</a>:</h4>
<p>'instruction counts' are a way to measure perf that's more reliable than wall time</p>



<a name="210816845"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210816845" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210816845">(Sep 22 2020 at 00:27)</a>:</h4>
<p>'incr-patched' is a small change to the code, like adding a <code>println!</code></p>



<a name="210816862"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210816862" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210816862">(Sep 22 2020 at 00:27)</a>:</h4>
<p><em>why</em> it happened I have no idea</p>



<a name="210817770"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210817770" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210817770">(Sep 22 2020 at 00:42)</a>:</h4>
<p>Sorry, I understood the meaning of the message, just it feels nonsensical.</p>



<a name="210817813"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210817813" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210817813">(Sep 22 2020 at 00:43)</a>:</h4>
<p>like, cc-rs should only be used to build native code, and I don't know how it can benefit from incremental builds as such.</p>



<a name="210817825"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210817825" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210817825">(Sep 22 2020 at 00:43)</a>:</h4>
<p>I mean, yay free speedups, but seems more likely to be noise</p>



<a name="210817877"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210817877" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210817877">(Sep 22 2020 at 00:44)</a>:</h4>
<p>but, as you said, instruction counts have less noise</p>



<a name="210818364"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818364" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818364">(Sep 22 2020 at 00:52)</a>:</h4>
<p>Hm do we have a diff of cc handy?</p>



<a name="210818561"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818561" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818561">(Sep 22 2020 at 00:56)</a>:</h4>
<p>We do link cc into run-time code</p>



<a name="210818611"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818611" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818611">(Sep 22 2020 at 00:56)</a>:</h4>
<p>But nothing in that diff looks obviously interesting (<a href="https://github.com/alexcrichton/cc-rs/compare/1.0.58...1.0.60">https://github.com/alexcrichton/cc-rs/compare/1.0.58...1.0.60</a>)</p>



<a name="210818636"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818636" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818636">(Sep 22 2020 at 00:57)</a>:</h4>
<p>Anyway, it looks basically doc-run only</p>



<a name="210818647"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818647" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> simulacrum <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818647">(Sep 22 2020 at 00:57)</a>:</h4>
<p>So let's not worry about it</p>



<a name="210818688"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818688" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818688">(Sep 22 2020 at 00:58)</a>:</h4>
<p>Not worrying is my forté.</p>



<a name="210818706"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818706" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818706">(Sep 22 2020 at 00:58)</a>:</h4>
<p>lol, that +1.2% showed up in an earlier perf run so this just undid it</p>



<a name="210818710"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818710" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818710">(Sep 22 2020 at 00:58)</a>:</h4>
<p>the +1.2 didn't make sense there either</p>



<a name="210818735"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818735" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818735">(Sep 22 2020 at 00:59)</a>:</h4>
<p>Someone hit the turbo button.</p>



<a name="210818736"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/247081-t-compiler/performance/topic/cc-rs%20update%20improved%20performance%3F/near/210818736" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Joshua Nelson <a href="https://rust-lang.github.io/zulip_archive/stream/247081-t-compiler/performance/topic/cc-rs.20update.20improved.20performance.3F.html#210818736">(Sep 22 2020 at 00:59)</a>:</h4>
<p>anyway, my position is still that no one should worry about rustdoc perf until rustdoc does: <a href="https://github.com/rust-lang/rust/blob/master/src/librustdoc/core.rs#L429-L438">https://github.com/rust-lang/rust/blob/master/src/librustdoc/core.rs#L429-L438</a></p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>